#!/bin/bash

cd /devel/dkpointsjs/WAR/root/scripts
rm closure-library-read-only

cd /devel/dkpointsjs/WAR/root/scripts/dkpointsjs/client-src/
rm dkpoints

cd /devel/dkpointsjs/WAR/root/
mv index.html index_development.html
mv index_production.html index.html

cd ../WEB-INF
mv app.yaml app_development.yaml
mv app_production.yaml app.yaml

cd /devel/dkpointsjs/
appcfg.sh update WAR

cd /devel/dkpointsjs/WAR/root/
mv index.html index_production.html
mv index_development.html index.html

cd ../WEB-INF
mv app.yaml app_production.yaml
mv app_development.yaml app.yaml

cd /devel/dkpointsjs/WAR/root/scripts
ln -s /devel/closure-library-read-only closure-library-read-only

cd /devel/dkpointsjs/WAR/root/scripts/dkpointsjs/client-src
ln -s /devel/dkpointsjs/client-src/dkpoints dkpoints
